﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;


namespace MapEntities
{


    [Serializable]
    public abstract class LayerItemBindingRule
    {
        private ItemBindingRule itemBindingrule = null;

        public LayerItemBindingRule()
        {
            ListingRule = new ListingBindingRule();
            BindingRule = new ItemBindingRule();
            ID = Guid.NewGuid();
        }

        public Guid ID { get; set; }
        public ListingBindingRule ListingRule { get; set; }


        public ItemBindingRule BindingRule
        {
            get
            {
                if (itemBindingrule == null)
                    itemBindingrule = new ItemBindingRule();
                return itemBindingrule;
            }
            set
            {
                itemBindingrule = value;
            }
        }
        public string TextBinding { get; set; }
        public string TooltipBinding { get; set; }

        public LayerInfo ViewLayer { get; set; }
        public string CustomLayer { get; set; }

    }
}
